/**
 * Copyright (c) 2018-2099, Chill Zhuang 庄骞 (bladejava@qq.com).
 * <p>
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 * <p>
 * http://www.apache.org/licenses/LICENSE-2.0
 * <p>
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package org.springblade.modules.restaurant.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springblade.core.mp.base.TenantEntity;

import java.io.Serial;
import java.math.BigDecimal;

/**
 * 采购货物实体类
 *
 * @author Blade
 * @since 2025-01-21
 */
@Data
@TableName("restaurant_purchase_commodity")
@EqualsAndHashCode(callSuper = true)
@Schema(description = "采购货物")
public class PurchaseCommodity extends TenantEntity {

	@Serial
	private static final long serialVersionUID = 1L;

	/**
	 * 采购类别ID
	 */
	@Schema(description = "采购类别ID")
	@JsonSerialize(using = ToStringSerializer.class)
	private Long categoryId;
	/**
	 * 类别名
	 */
	@Schema(description = "类别名")
	private String categoryName;
	/**
	 * 排序
	 */
	@Schema(description = "排序")
	private Integer sort;
	/**
	 * 货物名
	 */
	@Schema(description = "货物名")
	private String commodityName;
	/**
	 * 货物图
	 */
	@Schema(description = "货物图")
	private String productPicture;
	/**
	 * 单位
	 */
	@Schema(description = "单位")
	private String unit;

	/**
	 * 库存数量
	 */
	@Schema(description = "库存数量")
	private BigDecimal stockNumber;
	/**
	 * 库存单位
	 */
	@Schema(description = "库存单位")
	private String stockUnit;

	/**
	 * 参考单价
	 */
	@Schema(description = "参考单价")
	private BigDecimal referencePrice;
	/**
	 * 库存价值
	 */
	@Schema(description = "库存价值")
	private BigDecimal stockValue;

}
